﻿using System;
using System.Collections.Generic;


/// <summary>
/// 武器随机防抗
/// </summary>
[Serializable]
public class WeaponRandResistance : PropertyBase
{
    public PropertyValue<object> fireResistance = new PropertyValue<object>(2,GMConfig.KeyType.PercentKey + "fireResistance",GMConfig.PropertyType.FireResistance);
    public PropertyValue<object> iceResistance = new PropertyValue<object>(2,GMConfig.KeyType.PercentKey + "iceResistance",GMConfig.PropertyType.IceResistance);
    public PropertyValue<object> toxicResistance = new PropertyValue<object>(2,GMConfig.KeyType.PercentKey + "toxicResistance",GMConfig.PropertyType.ToxicResistance);
    public PropertyValue<object> blockResistance = new PropertyValue<object>(2,GMConfig.KeyType.PercentKey + "blockResistance",GMConfig.PropertyType.Block);

    public WeaponRandResistance()
    {
        propertyList.Add(fireResistance);
        propertyList.Add(iceResistance);
        propertyList.Add(toxicResistance);
        propertyList.Add(blockResistance);
    }
}

/// <summary>
/// 武器随机元素
/// </summary>
[Serializable]
public class WeaponRandElement : PropertyBase
{
    public const string key = "ElementalInjury_";
    public PropertyValue<object> fireElemental = new PropertyValue<object>(1,key + "fireElemental",GMConfig.PropertyType.FireElement);
    public PropertyValue<object> iceElemental = new PropertyValue<object>(1,key + "iceElemental",GMConfig.PropertyType.IceElement);
    public PropertyValue<object> toxicElemental = new PropertyValue<object>(1,key + "toxicElemental",GMConfig.PropertyType.ToxicElement);

    public WeaponRandElement()
    {
        propertyList.Add(fireElemental);
        propertyList.Add(iceElemental);
        propertyList.Add(toxicElemental);
    }
}
/// <summary>
/// 其它武器随机
/// </summary>
[Serializable]
public class WeaponRandOther : PropertyBase
{
    public PropertyValue<object> fireResistance = new PropertyValue<object>(2,GMConfig.KeyType.PercentKey + "fireResistance",GMConfig.PropertyType.FireResistance);
    public PropertyValue<object> iceResistance = new PropertyValue<object>(2,GMConfig.KeyType.PercentKey + "iceResistance",GMConfig.PropertyType.IceResistance);
    public PropertyValue<object> toxicResistance = new PropertyValue<object>(2,GMConfig.KeyType.PercentKey + "toxicResistance",GMConfig.PropertyType.ToxicResistance);
    public PropertyValue<object> blockResistance = new PropertyValue<object>(2,GMConfig.KeyType.PercentKey + "blockResistance",GMConfig.PropertyType.Block);
    public PropertyValue<object> weaponDamage = new PropertyValue<object>(2,GMConfig.KeyType.AddKey + "weaponDamage",GMConfig.PropertyType.WeaponDamage);

    public WeaponRandOther()
    {
        propertyList.Add(fireResistance);
        propertyList.Add(iceResistance);
        propertyList.Add(toxicResistance);
        propertyList.Add(blockResistance);
        propertyList.Add(weaponDamage);
    }
}

/// <summary>
/// 装备所有可随机属性
/// </summary>
public class EquipmentRand{
    public static WeaponRandResistance weaponRandResistance = new WeaponRandResistance();
    public static WeaponRandElement weaponRandElement = new WeaponRandElement();
    public static WeaponRandOther weaponRandOther = new WeaponRandOther();
}